<include file="Common@header:header"/>

<script src="__PUBLIC__/static/jquery-1.10.2.min.js"></script>
<script src="__PUBLIC__/static/kindeditor/kindeditor-min.js"></script>
<script>
    var editor;
    KindEditor.ready(function (K) {
        editor = K.create('textarea[name="content"]', {
            resizeType: 1,
            allowPreviewEmoticons: false,
            allowImageUpload: false,
            items: [
                'fontname', 'fontsize', '|', 'forecolor', 'hilitecolor', 'bold', 'italic', 'underline',
                'removeformat', '|', 'justifyleft', 'justifycenter', 'justifyright', 'insertorderedlist',
                'insertunorderedlist', '|', 'emoticons', 'image', 'link']
        });
    });
</script>

<include file="Common@sitting:sitting"/>
<!--main-->
<div class="user_main">

    <div class="uMain_content">


        <div class="minHeight500">
            <!--修改添加文章-->
            <form id="doprofile" action="{{:U('Blog/Article/insert')}}" method="post">
                <div id="modifyProfile" class="profile">
                    <div class="title">
                        <div class="name">添加文章</div>
                    </div>
                    <dl class="form">
                        <dd>文章分类：<select name="cid" id="nav">
                            <option value="0" selected="selected">--------顶级分类---------</option>

                            <article:clist name='vo'>
                                <option value="{{$vo.id}}">{{$vo.catname}}</option>
                            </article:clist>
                        </select> <span class="red">[必选]</span>
                        </dd>

                        <dd>文章标题：<input type="text" name="title" class="text" id="sn" onblur="checkSn();"/> <span
                                class="red">[必填]</span> ( * 2-100字符之间 )
                        </dd>
                        <dd>文章标签：<input type="text" name="tags" class="text"/> <span class="red">[必填]</span> ( *
                            每个标签','隔开)
                        </dd>
                        <!--<dd>文章摘要：<input type="text" name="keyword" class="text"/> ( * 例：纯棉|换季|白色；每个关键字用'|'隔开)</dd>-->


                        <dd>上传图片：<input type="text" name="thumbnail" class="text" readonly="readonly"/>
                        <input type="button" value="上传产品图"
                        onclick="centerWindow('?a=call&m=upfile&type=content','upfile','400','150')"/>
                        <img name="pic" style="display:none;"/> ( * 必须是jpg,gif,png，并且200k内)
                        </dd>
                        <dd>
                            <textarea id="TextArea1" name="content" class="ckeditor"
                                      style="width:750px;height:400px;"></textarea>
                        </dd>

                        <dd>
                            <input type="submit" name="send" value="添加文章" onclick=""/>
                            <input type="reset" value="重置"/>
                        </dd>
                    </dl>
                </div>
            </form>

        </div>
    </div>


</div>
<!--main-->


<div style="clear: both;"></div>
<include file="Common@footer:footer"/>
<script type="text/javascript">
    $(function () {
        $('.tabUl li').click(function () {
            $(this).addClass('current').siblings().removeClass('current');
            var num = $('.tabUl li').index(this);
            $('.profile').hide().eq(num).show();
        });
    })

</script>